<?php
namespace App\Models;

use App\Models\Simple\CSVModel;

use CodeIgniter\Model; 
/*
 * Mock travel destination data.
 * Note that we don't have to extend CodeIgniter's model for now
 */

class Athletes extends Model{

    protected $table = 'athletes'; 
    protected $allowedFields = ['Name', 'Gender', 'Date_of_Birth', 'Height', 'Weight','Playing_Style','Place_of_Birth','image'];

    protected $validationRules = [
        'Name' => 'required|min_length[3]|max_length[255]',
        'Gender' => 'required|min_length[3]|max_length[255]',
        'Date_of_Birth' => 'required|min_length[3]|max_length[20]',
        'Height' => 'required|min_length[3]|max_length[10]',
        'Weight' => 'required|min_length[3]|max_length[50]',
        'Playing_Style' => 'required|min_length[3]|max_length[255]',
        'Place_of_Birth' => 'required|min_length[3]|max_length[255]',
        'image' => 'required|min_length[3]|max_length[255]',
    ];
}

